
import { defineComponent} from "vue";
import {useStore} from "vuex"

export default defineComponent({
  emits:{
    'delete':null
  },
  setup(props,ctx) {
    const store = useStore()
    const data = [{name:"删除",icon:'iconshanchu'}]
    const click=()=>{
      ctx.emit("delete")
    }
    return () => (
          <div class="rightMeau" style={{marginLeft:`${store.state.rightClick.position.x}px`,marginTop:`${store.state.rightClick.position.y-100}px`,
          display:store.state.rightClick.show?'block':'none'}} >
          {data.map(item=>{
          return <div class="flex rightBox" onClick={()=>click()}>
              <Icon-font type={item.icon} style={{ color: '#fff', fontSize: '14px' }} />
              <div style={{marginLeft:"10px"}} >{item.name}</div>
            </div>
            })}
          </div>
    );
  },
});

